<?php
/* PitchSubscription Test cases generated on: 2010-11-16 11:11:37 : 1289902897*/
App::import('Model', 'PitchSubscription');

class PitchSubscriptionTestCase extends CakeTestCase {
	var $fixtures = array('app.message', 'app.user', 'app.group', 'app.contractor_profile', 'app.designer_profile', 'app.comment', 'app.design', 'app.pitch', 'app.pitch_subscription', 'app.design_photo', 'app.job');

	function startTest() {
		$this->PitchSubscription =& ClassRegistry::init('PitchSubscription');
	}

	function endTest() {
		unset($this->PitchSubscription);
		ClassRegistry::flush();
	}
	
	function testFindSubscribed() {
		$result = $this->PitchSubscription->find_subscribed(4);
		$result = count($result);
		$expected = 2;
		$this->assertEqual($result, $expected);
		
		$result = $this->PitchSubscription->find_subscribed(4, true);
		$result = count($result);
		$expected = 1;
		$this->assertEqual($result, $expected);
		
		$result = $this->PitchSubscription->find_subscribed(1, true);
		$result = count($result);
		$expected = 1;
		$this->assertEqual($result, $expected);
	}

}
?>
